

########################################
#
#
#
#
#

require File.join(File.expand_path(File.dirname(__FILE__)), 'base.rb')


def create_view name
    # Write HTML file
    content = ruby_template './Rbts/view.rbt'
    content.gsub!(/\{%\$name%\}/, name.downcase)
    path = project_widget_path group, Everest::TypeView
    result = create_file path, "#{name.downcase}.html", content
end

# Main
if $mode_name == Everest::ModeNew
  puts "Create View '#{$module_name}'."
  create_view $module_name
elsif $mode_name == Everest::ModeDelete
  puts "Delete View '#{$module_name}'."

elsif $mode_name == 'ls'
  puts "List all views."
end



